package com.mangoerp.error;

import com.alibaba.csp.sentinel.slots.block.BlockException;
import com.mangoerp.common.Result;

/**
 * @author yincb
 */
public class  ExceptionHandler {

    public static Result fallback(Integer id, Throwable e){
        return Result.error(-200,"=========被异常降级啦===");
    }

    public static Result handleException(Integer id, BlockException e){
        return Result.error(-100,"==========被限流啦===");
    }
}
